package com.gwt.theOne.theLocal.client;

import com.google.gwt.user.client.rpc.AsyncCallback;
import com.gwt.theOne.theLocal.shared.CurrentWeather;
import com.gwt.theOne.theLocal.shared.DiggInfo;
import com.gwt.theOne.theLocal.shared.GoogleNews;
import com.gwt.theOne.theLocal.shared.LoginInfo;

public interface FetchDataServiceAsync {

  void getDiggInfo(String city, boolean isSortByDate, boolean isIncNeighborChked, AsyncCallback<DiggInfo[]> callback);

  void loadLocationNames(AsyncCallback<Boolean> callback);

  void getLocationNames(AsyncCallback<String[]> callback);

  void validateUserLogin(String requestUri, AsyncCallback<LoginInfo> callback);

  void addUserComment(String locName, String nickname, String emailAddress,
		String commentHtml, AsyncCallback<Boolean> callback);

  void getNews(String cityname, boolean sortedByRelevance, boolean includeNearbyCities, AsyncCallback<GoogleNews[]> callback)
	throws IllegalArgumentException;
  
  void getUserComments(String location, boolean isIncNeighborChked,
		AsyncCallback<String[][]> callback); 
  
  void insertNearbyPlacesIntoDatabase(AsyncCallback<Boolean> callback)
	throws IllegalArgumentException;
  
  void getWeatherNews(String cityName, AsyncCallback<CurrentWeather> callback)
	throws IllegalArgumentException;

}
